import request from "@/utils/request";

//短信电话列表
export function telList(params) {
  return request({
    url: "channel/message/tel-list",
    method: "get",
    params,
  });
}
//保存短信 get 查看数据 post 提交数据
export function saveTel(data) {
  return request({
    url: "channel/message/save-tel",
    method: "post",
    data,
  });
}
//删除电话
export function delTel(data) {
  return request({
    url: "channel/message/del-tel",
    method: "post",
    data,
  });
}
//打印机列表
export function printList(params) {
  return request({
    url: "channel/message/print-list",
    method: "get",
    params,
  });
}
//保存打印机 get 查看数据 post 提交数据
export function getSavePrint(params) {
  return request({
    url: "channel/message/save-print",
    method: "get",
    params,
  });
}
export function postSavePrint(data) {
  return request({
    url: "channel/message/save-print",
    method: "post",
    data,
  });
}
//修改打印机
export function modifyPrint(data) {
  return request({
    url: "channel/message/modify-print",
    method: "post",
    data,
  });
}
//测试打印
export function printTest(data) {
  return request({
    url: "channel/message/print-test",
    method: "post",
    data,
  });
}

//评价管理
//获取评价列表
export function getCommentList(params) {
  return request({
    url: "channel/comment/get-comment-list",
    method: "get",
    params,
  });
}
//删除评价信息
export function commentDel(data) {
  return request({
    url: "channel/comment/comment-del",
    method: "post",
    data,
  });
}
//审核评价信息
export function changeComment(data) {
  return request({
    url: "channel/comment/change-comment",
    method: "post",
    data,
  });
}
//商家回复评价信息
export function commentReply(data) {
  return request({
    url: "channel/comment/comment-reply",
    method: "post",
    data,
  });
}

//订单处理
//获取订单列表
export function orderList(params) {
  return request({
    url: "channel/order/order-list",
    method: "get",
    params,
  });
}
//查看自提订单
export function getModifyOrder(params) {
  return request({
    url: "channel/order/modify-order",
    method: "get",
    params,
  });
}
//查看自提订单待核销数量
export function waitWriteOff(params) {
  return request({
    url: "channel/order/wait-write-off",
    method: "get",
    params,
  });
}
//操作订单
export function modifyOrder(data) {
  return request({
    url: "channel/order/modify-order",
    method: "post",
    data,
  });
}
//查看订单详情
export function orderContent(params) {
  return request({
    url: "channel/order/print-content",
    method: "get",
    params,
  });
}
//查看绑定列表
export function bundList(params) {
  return request({
    url: "channel/message/open-id-list",
    method: "get",
    params,
  });
}
//添加绑定
export function addBund(data) {
  return request({
    url: "channel/message/save-open-id",
    method: "post",
    data,
  });
}
//解绑
export function unBand(data) {
  return request({
    url: "channel/message/unbundling",
    method: "post",
    data,
  });
}
//获取饿了么订单
export function getEleOrder(params) {
  return request({
    url: "channel/ele/get-ele-order",
    method: "get",
    params,
  });
}
//操作饿了么订单
export function modifyEleOrder(data) {
  return request({
    url: "channel/ele/modify-ele-order",
    method: "post",
    data,
  });
}

//操作饿了么订单
export function newOrder(data) {
  return request({
    url: "channel/order/rewire-order",
    method: "post",
    data,
  });
}
//订单统计
export function orderStatistic(params) {
  return request({
    url: "channel/order/order-statistic",
    method: "get",
    params,
  });
}
export function confirmReminder(params) {
  return request({
    url: 'channel/order/reminder',
    method: 'get',
    params
  })
}
